package com.wyx.system.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Collection;
import java.util.Collections;
import java.util.List;

import lombok.Data;
import org.springframework.security.core.GrantedAuthority;
import org.springframework.security.core.userdetails.UserDetails;

/**
 * 用户
 * @TableName sys_user
 */
@TableName(value ="sys_user")
@Data
public class SysUser implements UserDetails,Serializable {

    @Override
    public Collection<? extends GrantedAuthority> getAuthorities() {
        return Collections.emptyList();
    }

    @Override
    public String getPassword() {
        return "";
    }

    @Override
    public String getUsername() {
        return "";
    }

    @Override
    public boolean isAccountNonExpired() {
        return false;
    }

    @Override
    public boolean isAccountNonLocked() {
        return false;
    }

    @Override
    public boolean isCredentialsNonExpired() {
        return false;
    }

    @Override
    public boolean isEnabled() {
        return false;
    }

    /**
     * 生成的id
     */
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 唯一值  uuid
     */
    private String uuid;

    /**
     * 生成的唯一id
     */
    private Long userId;

    /**
     *
     */
    private String userName;

    /**
     * 微信
     */
    private String wechet;

    /**
     * 手机
     */
    private String phone;

    /**
     *
     */
    private String pwd;

    /**
     *
     */
    private String img;

    /**
     * 状态值  0   代表正常 1 代表锁定 2 禁用 3 代表 死亡
     */
    private String status;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;


}
